﻿@using QDT.Common
@model System.Collections.Generic.IList<QDT.Core.Projects.ProjectImage>

@{
    ViewBag.Title = "title";
}

<div class="main_title">
    相关资料
</div>
<div class="blank5">
</div>
<div class="blank5">
</div>
<div class="grid_box">
    <div class="grid_top">
    </div>
  
    <p style="text-align: center;background-color: #ccc;line-height: 50px">第一排(合同协议)</p>
      @Html.ActionLink("新增", "AddImage", new { id = ViewContext.RouteData.Values["id"], title = "第一排" }, new { @class = "button" })
    @Html.Grid(Model.Where(x=>x.Title.Contains("第一排"))).Columns(column =>
{
                                  column.For(x => x.ID).Named("编号").HeaderAttributes(style => "width:50px;");
                                  column.For(x => Html.ActionLink(x.Title, "EditImage", new
                                  {
                                                                                              })).Named("标题").SortColumnName("Title");
                                  column.For(x => new HtmlString("<img src=\"" + x.Thumbnail + "\" style='width:96px;height:68px'/>")).Named("缩略图").Sortable(false);
                                  column.For(x => x.Sort).Named("排序").HeaderAttributes(style => "width:50px;");
                                  ;
                                  column.For(x => x.CreateTime).Named("创建时间").HeaderAttributes(style => "width:180px;").SortColumnName("CreateTime");

                                  column.Buttons(btns => btns.Add(x => Html.ActionLink("编辑", "EditImage", new {
                                                                                                                  id = x.ID
                                                                                                              }))
                                                             .Add(x => Html.ScriptLink("彻底删除", "deleteMethod({0},'{1}')", x.ID, "DeleteImage"))
                                                             .Add(x => new HtmlString("<a href='{0}' target='_blank'>大图预览</a>".FormatWith(x.Photo))));
                              
        }).Complex(ViewData)
    <p style="text-align: center;background-color: #ccc;line-height: 50px">第二排(资质证件)</p>
      @Html.ActionLink("新增", "AddImage", new { id = ViewContext.RouteData.Values["id"], title = "第二排" }, new { @class = "button" })
          @Html.Grid(Model.Where(x=>x.Title.Contains("第二排"))).Columns(column =>
{
                                  column.For(x => x.ID).Named("编号").HeaderAttributes(style => "width:50px;");
                                  column.For(x => Html.ActionLink(x.Title, "EditImage", new
                                  {
                                                                                                  id = x.ID
                                                                                              })).Named("标题").SortColumnName("Title");
                                  column.For(x => new HtmlString("<img src=\"" + x.Thumbnail + "\" style='width:96px;height:68px'/>")).Named("缩略图").Sortable(false);
                                  column.For(x => x.Sort).Named("排序").HeaderAttributes(style => "width:50px;");
                                  ;
                                  column.For(x => x.CreateTime).Named("创建时间").HeaderAttributes(style => "width:180px;").SortColumnName("CreateTime");

                                  column.Buttons(btns => btns.Add(x => Html.ActionLink("编辑", "EditImage", new {
                                                                                                                  id = x.ID
                                                                                                              }))
                                                             .Add(x => Html.ScriptLink("彻底删除", "deleteMethod({0},'{1}')", x.ID, "DeleteImage"))
                                                             .Add(x => new HtmlString("<a href='{0}' target='_blank'>大图预览</a>".FormatWith(x.Photo))));
                              
        }).Complex(ViewData)
    <p style="text-align: center;background-color: #ccc;line-height: 50px">第三排(企业实地照片)</p>
      @Html.ActionLink("新增", "AddImage", new {id=ViewContext.RouteData.Values["id"],title="第三排"}, new {@class = "button"})
         @Html.Grid(Model.Where(x=>x.Title.Contains("第三排"))).Columns(column =>
{
                                  column.For(x => x.ID).Named("编号").HeaderAttributes(style => "width:50px;");
                                  column.For(x => Html.ActionLink(x.Title, "EditImage", new
                                  {
                                                                                                  id = x.ID
                                                                                              })).Named("标题").SortColumnName("Title");
                                  column.For(x => new HtmlString("<img src=\"" + x.Thumbnail + "\" style='width:96px;height:68px'/>")).Named("缩略图").Sortable(false);
                                  column.For(x => x.Sort).Named("排序").HeaderAttributes(style => "width:50px;");
                                  ;
                                  column.For(x => x.CreateTime).Named("创建时间").HeaderAttributes(style => "width:180px;").SortColumnName("CreateTime");

                                  column.Buttons(btns => btns.Add(x => Html.ActionLink("编辑", "EditImage", new {
                                                                                                                  id = x.ID
                                                                                                              }))
                                                             .Add(x => Html.ScriptLink("彻底删除", "deleteMethod({0},'{1}')", x.ID, "DeleteImage"))
                                                             .Add(x => new HtmlString("<a href='{0}' target='_blank'>大图预览</a>".FormatWith(x.Photo))));
                              
        }).Complex(ViewData)
    <div class="grid_foot">
    </div>
</div>
<div class="blank5">
</div>
